package com.xj.test.module_a.impl

import com.xj.test.module_a_provider.ModuleAService
import com.xj.test.module_a_provider.bean.ModuleABean
import kotlinx.coroutines.delay
import kotlinx.coroutines.flow.Flow
import kotlinx.coroutines.flow.flow
import javax.inject.Inject


class ModuleAServiceImpl @Inject constructor() : ModuleAService {
    override fun getModuleABean(): Flow<ModuleABean> {
        return flow {
            delay(3000)
            emit(ModuleABean("我来自 ${this@ModuleAServiceImpl.javaClass.name}"))
        }
    }
}